package com.weiyi.portal.modules.pms.controller;


import com.weiyi.common.common.api.CommonResult;
import com.weiyi.portal.dto.PmsProductDTO;
import com.weiyi.portal.modules.pms.service.PmsProductService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

/**
 * <p>
 * 商品信息 前端控制器
 * </p>
 *
 * @author PZC
 * @since 2022-10-13
 */
@RestController
@RequestMapping("/pms/pmsProduct")
public class PmsProductController {
    @Autowired
    PmsProductService pmsProductService;

    /**
     * 测试用例
     * @param pmsProductDTO
     * @return
     */
    @RequestMapping(value = "/create", method = RequestMethod.POST)
    public CommonResult create(PmsProductDTO pmsProductDTO){
        Boolean result = pmsProductService.create(pmsProductDTO);
        if(result)return CommonResult.success(result);
        return CommonResult.failed();
    }



}

